﻿using System.Web.Mvc;
using Common;
using Models;
using Web.Areas.Admin.Lib;
using Web.Lib;

namespace Web.Areas.Admin.Controllers
{
    public class HomeController : Controller
    {
        public ActionResult Index()
        {
            if (Account.ID > 0)
            {
                var user = new admin_accountLogic().Getadmin_account(Account.ID);
                return View(user);
            }
            else
            {
                return Redirect("/admin/account/logon");
            }
        }

        public ActionResult Profile()
        {
            var user = new admin_accountLogic().Getadmin_account(Account.ID);

            return View(user);
        }
    }
}
